import Vue from 'vue'
import Vuex from 'vuex'
import app from './modules/app'
import user from './modules/user'
import permission from './modules/permission'
import getters from './getters'
import defaultState from './defaultState'
Vue.use(Vuex)

const store = new Vuex.Store({
  state:defaultState,
  mutations:{
    SET_AREAS(state,value){
      state.areas = value;
    },
    SET_MATCHLIST(state,value){
      state.matchList = value;
    },
    SET_TANMA(state,value){
      state.tanma = value;
    },
    SET_ISTANMA(state,value){
      state.isTanma = value;
    },
    ERROR_CLIENT_LIST(state, value) {
      state.errorList = value;
    }
   
  },
  modules: {
    app,
    user,
    permission,
    Storage
  },
  getters
})

export default store
